<?php
require_once 'upload1.func.php';
require_once 'comon.func.php';

$files=getFiles();
foreach($files as $fileInfo)
{
    $res = uploadFile($fileInfo);
    echo $res['mes'],'</br>';
    $uploadFiles [] = $res['dest'];
}
$uploadFiles=array_filter($uploadFiles);
var_dump($uploadFiles);